<!--
  @author duanzuocai
  @since 2018/10/19 23:12
-->
<!DOCTYPE html SYSTEM "http://www.thymeleaf.org/dtd/xhtml1-strict-thymeleaf-4.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">

<head th:include="common/common :: jscss">
    <title>新增数据权限</title>
</head>
<body>

<div class="layui-fluid">

    <blockquote class="layui-elem-quote layui-text">
        <a th:lay-href="@{/mc/staff/staffPermitList.action(staffId=${staff.staffId})}">员工权限管理</a>&nbsp;&nbsp;>&nbsp;新增数据权限
    </blockquote>

    <div class="layui-card">
        <form method="post" action="" class="layui-form" lay-filter="zmn-permitdata-form">

            <input type="hidden" name="staffId" th:value="${staff.staffId}"/>

            <div class="layui-card-header" style="margin-top:10px;"><b>基本信息</b></div>
            <div class="layui-split">&nbsp;</div>

            <div class="layui-form-item">
                <label class="layui-form-label">姓名</label>
                <div class="layui-input-block">
                    <div class="layui-form-mid layui-word-aux">
                        <span th:text="${staff.realName}"></span>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">类型</label>
                <div class="layui-input-inline">
                    <select name="type" id="type" lay-filter="typeFilter">
                        <option th:each="type:${types}" th:value="${type.key}" th:text="${type.value}">
                    </select>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">类型数据</label>
                <div class="layui-input-inline" style="width: 80%" id="data_type_div_id">

                </div>
            </div>

            <div class="layui-split">&nbsp;</div>
            <div class="layui-form-item layui-layout-admin">
                <div class="layui-input-block">
                    <div class="layui-footer" style="left: 0;">
                        <button class="layui-btn" lay-submit="" lay-filter="zmn-permitdata-form-submit">保存</button>
                        <button class="layui-btn layui-btn-primary" onclick="cancel()">取消</button>
                    </div>
                </div>
            </div>

        </form>

    </div>

</div>

<script type="text/javascript" th:inline="javascript">

    var json = {
        companys: [[${companys}]],
        permitDataList: [[${permitDataList}]],
        deptId: [[${staff.deptId}]],
        staffId: [[${staff.staffId}]]
    };

    layui.config({
        base: "/static/lay/"
    }).extend({
        index: "lib/index",
        art_staffpermitdata_detail: "mc/staffpermitdata/zmn.art.staffpermitdata.edit",
    }).use(['index', 'art_staffpermitdata_detail']);

</script>
</body>
</html>